package com.kaili.basic.controller;

import com.baomidou.mybatisplus.plugins.Page;
import com.kaili.basic.pojo.dto.DeviceDTO;
import com.kaili.basic.pojo.dto.DeviceSumDTO;
import com.kaili.basic.pojo.vo.DeviceSumVO;
import com.kaili.basic.pojo.vo.DeviceVO;
import com.kaili.basic.service.IIndexService;
import com.kaili.basic.version.ApiVersion;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Desc: 首页控制类
 * @author: zhouyijian
 * @Time: 2019/7/31 20:37
 * @Copyright: © 2018 杭州凯立通信有限公司 版权所有
 * @Warning: 本内容仅限于公司内部传阅, 禁止外泄或用于其它商业目的
 */

@ApiVersion(1)
@RequestMapping("/{api_version}")
@RestController
@Api(tags = "首页", description = "首页相关API")
public class IndexController {
    @Autowired
    private IIndexService indexService;
    @GetMapping(value = "/device/index")
    @ApiOperation("首页")
    public List<DeviceSumVO> queryDeviceSumList(DeviceSumDTO dto) {
        List<DeviceSumVO> result =indexService.queryDeviceSumList(dto);
        return result;
    }


}
